```html
<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Spring AOP 通知类型详解</title>
    <link href="https://cdn.staticfile.org/font-awesome/6.4.0/css/all.min.css" rel="stylesheet">
    <link href="https://cdn.staticfile.org/tailwindcss/2.2.19/tailwind.min.css" rel="stylesheet">
    <link href="https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@400;500;600;700&family=Noto+Sans+SC:wght@300;400;500;700&display=swap" rel="stylesheet">
    <script src="https://cdn.jsdelivr.net/npm/mermaid@latest/dist/mermaid.min.js"></script>
    <style>
        body {
            font-family: 'Noto Sans SC', Tahoma, Arial, Roboto, "Droid Sans", "Helvetica Neue", "Droid Sans Fallback", "Heiti SC", "Hiragino Sans GB", Simsun, sans-serif;
            color: #333;
            line-height: 1.6;
        }
        .hero {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        }
        h1, h2, h3, h4 {
            font-family: 'Noto Serif SC', serif;
            font-weight: 700;
        }
        .code-block {
            background-color: #2d3748;
            border-radius: 8px;
            position: relative;
        }
        .code-block pre {
            margin: 0;
            padding: 1.5rem;
            color: #e2e8f0;
            overflow-x: auto;
        }
        .code-block::before {
            content: '';
            position: absolute;
            top: 0;
            right: 0;
            width: 100%;
            height: 40px;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 8px 8px 0 0;
        }
        .notification-card {
            transition: all 0.3s ease;
            border-left: 4px solid;
        }
        .notification-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
        }
        .notification-icon {
            font-size: 2rem;
            margin-bottom: 1rem;
        }
    </style>
</head>
<body class="bg-gray-50">
    <!-- Hero Section -->
    <section class="hero text-white py-20 px-4 md:py-32">
        <div class="container mx-auto max-w-6xl">
            <div class="flex flex-col items-center text-center">
                <h1 class="text-4xl md:text-5xl font-bold mb-6">Spring AOP 通知类型详解</h1>
                <p class="text-xl md:text-2xl max-w-3xl mb-8 opacity-90">
                    掌握面向切面编程的核心概念，实现优雅的横切关注点处理
                </p>
                <div class="flex space-x-4">
                    <a href="#content" class="px-6 py-3 bg-white text-indigo-700 rounded-lg font-semibold hover:bg-opacity-90 transition">
                        开始学习
                    </a>
                    <a href="#mermaid-chart" class="px-6 py-3 border-2 border-white text-white rounded-lg font-semibold hover:bg-white hover:bg-opacity-10 transition">
                        查看图表
                    </a>
                </div>
            </div>
        </div>
    </section>

    <!-- Main Content -->
    <main id="content" class="container mx-auto max-w-6xl px-4 py-12">
        <div class="prose prose-lg max-w-none">
            <p class="text-gray-700 leading-relaxed mb-8">
                在 Spring 框架中，通知（Advice）是 AOP（面向切面编程）的核心概念之一。通知是指在特定的连接点（例如方法调用）上执行的代码。Spring AOP 支持多种类型的通知，通过这些通知，开发者可以在不修改目标方法代码的情况下，插入横切关注点，如日志记录、安全检查、性能监控等。了解和掌握这些通知类型能够帮助开发者更好地利用 Spring AOP 实现灵活的应用程序功能。
            </p>
        </div>

        <!-- Before Advice -->
        <div class="my-12">
            <div class="notification-card bg-white rounded-lg shadow-lg p-8 mb-8 border-l-4 border-blue-500">
                <div class="flex flex-col md:flex-row items-start">
                    <div class="md:w-1/3 mb-6 md:mb-0 md:pr-8">
                        <div class="flex items-center mb-4">
                            <i class="notification-icon fas fa-arrow-circle-right text-blue-500"></i>
                            <h2 class="text-2xl font-bold ml-3">前置通知（Before Advice）</h2>
                        </div>
                        <p class="text-gray-700">
                            <strong>作用：</strong>在目标方法执行之前执行的通知。用于在目标方法之前执行某些操作，例如权限检查、日志记录等。
                        </p>
                        <p class="text-gray-700 mt-2">
                            <strong>实现：</strong>使用 <code>@Before</code> 注解。
                        </p>
                    </div>
                    <div class="md:w-2/3">
                        <div class="code-block">
                            <pre><code>@Before("execution(* com.ts.service.MyService.*(..))")
public void beforeAdvice(JoinPoint joinPoint) {
    System.out.println("前置通知：方法执行前的操作");
}</code></pre>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- After Advice -->
        <div class="my-12">
            <div class="notification-card bg-white rounded-lg shadow-lg p-8 mb-8 border-l-4 border-purple-500">
                <div class="flex flex-col md:flex-row items-start">
                    <div class="md:w-1/3 mb-6 md:mb-0 md:pr-8">
                        <div class="flex items-center mb-4">
                            <i class="notification-icon fas fa-arrow-circle-down text-purple-500"></i>
                            <h2 class="text-2xl font-bold ml-3">后置通知（After Advice）</h2>
                        </div>
                        <p class="text-gray-700">
                            <strong>作用：</strong>在目标方法执行之后执行的通知，无论目标方法执行成功还是失败。通常用于资源释放、清理工作等。
                        </p>
                        <p class="text-gray-700 mt-2">
                            <strong>实现：</strong>使用 <code>@After</code> 注解。
                        </p>
                    </div>
                    <div class="md:w-2/3">
                        <div class="code-block">
                            <pre><code>@After("execution(* com.ts.service.MyService.*(..))")
public void afterAdvice(JoinPoint joinPoint) {
    System.out.println("后置通知：方法执行后的操作");
}</code></pre>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- After Returning Advice -->
        <div class="my-12">
            <div class="notification-card bg-white rounded-lg shadow-lg p-8 mb-8 border-l-4 border-green-500">
                <div class="flex flex-col md:flex-row items-start">
                    <div class="md:w-1/3 mb-6 md:mb-0 md:pr-8">
                        <div class="flex items-center mb-4">
                            <i class="notification-icon fas fa-check-circle text-green-500"></i>
                            <h2 class="text-2xl font-bold ml-3">返回通知（After Returning Advice）</h2>
                        </div>
                        <p class="text-gray-700">
                            <strong>作用：</strong>在目标方法成功执行之后执行的通知。用于处理目标方法成功返回后的逻辑，例如对返回结果的处理或日志记录。
                        </p>
                        <p class="text-gray-700 mt-2">
                            <strong>实现：</strong>使用 <code>@AfterReturning</code> 注解。
                        </p>
                    </div>
                    <div class="md:w-2/3">
                        <div class="code-block">
                            <pre><code>@AfterReturning(pointcut = "execution(* com.ts.service.MyService.*(..))", returning = "result")
public void afterReturningAdvice(JoinPoint joinPoint, Object result) {
    System.out.println("返回通知：方法返回值为：" + result);
}</code></pre>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- After Throwing Advice -->
        <div class="my-12">
            <div class="notification-card bg-white rounded-lg shadow-lg p-8 mb-8 border-l-4 border-red-500">
                <div class="flex flex-col md:flex-row items-start">
                    <div class="md:w-1/3 mb-6 md:mb-0 md:pr-8">
                        <div class="flex items-center mb-4">
                            <i class="notification-icon fas fa-exclamation-circle text-red-500"></i>
                            <h2 class="text-2xl font-bold ml-3">异常通知（After Throwing Advice）</h2>
                        </div>
                        <p class="text-gray-700">
                            <strong>作用：</strong>在目标方法抛出异常时执行的通知。用于异常处理、日志记录或通知发送等。
                        </p>
                        <p class="text-gray-700 mt-2">
                            <strong>实现：</strong>使用 <code>@AfterThrowing</code> 注解。
                        </p>
                    </div>
                    <div class="md:w-2/3">
                        <div class="code-block">
                            <pre><code>@AfterThrowing(pointcut = "execution(* com.ts.service.MyService.*(..))", throwing = "exception")
public void afterThrowingAdvice(JoinPoint joinPoint, Exception exception) {
    System.out.println("异常通知：方法抛出了异常：" + exception);
}</code></pre>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- Around Advice -->
        <div class="my-12">
            <div class="notification-card bg-white rounded-lg shadow-lg p-8 mb-8 border-l-4 border-yellow-500">
                <div class="flex flex-col md:flex-row items-start">
                    <div class="md:w-1/3 mb-6 md:mb-0 md:pr-8">
                        <div class="flex items-center mb-4">
                            <i class="notification-icon fas fa-sync-alt text-yellow-500"></i>
                            <h2 class="text-2xl font-bold ml-3">环绕通知（Around Advice）</h2>
                        </div>
                        <p class="text-gray-700">
                            <strong>作用：</strong>在目标方法执行前、执行后都可以进行操作，并且可以控制目标方法是否执行。环绕通知是最强大的一种通知类型，能够完全控制目标方法的执行。
                        </p>
                        <p class="text-gray-700 mt-2">
                            <strong>实现：</strong>使用 <code>@Around</code> 注解，并且需要实现 <code>ProceedingJoinPoint</code>。
                        </p>
                    </div>
                    <div class="md:w-2/3">
                        <div class="code-block">
                            <pre><code>@Around("execution(* com.ts.service.MyService.*(..))")
public Object aroundAdvice(ProceedingJoinPoint joinPoint) throws Throwable {
    System.out.println("环绕通知：方法执行前");
    Object result = joinPoint.proceed(); // 执行目标方法
    System.out.println("环绕通知：方法执行后");
    return result;
}</code></pre>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <!-- Mermaid Diagram -->
        <div id="mermaid-chart" class="my-20 bg-white rounded-lg shadow-lg p-8">
            <h2 class="text-3xl font-bold mb-8 text-center">Spring AOP 通知执行顺序图示</h2>
            <div class="mermaid">
                sequenceDiagram
                    participant Client
                    participant Proxy
                    participant Target

                    Client->>Proxy: 调用方法
                    Proxy->>+Before Advice: 前置通知
                    Before Advice-->>-Proxy: 
                    Proxy->>+Target: 方法调用
                    alt 正常执行
                        Target-->>-Proxy: 返回结果
                        Proxy->>+AfterReturning Advice: 返回通知
                        AfterReturning Advice-->>-Proxy: 
                    else 异常情况
                        Target--xProxy: 抛出异常
                        Proxy->>+AfterThrowing Advice: 异常通知
                        AfterThrowing Advice-->>-Proxy: 
                    end
                    Proxy->>+After Advice: 后置通知
                    After Advice-->>-Proxy: 
                    Proxy-->>Client: 返回结果或异常
            </div>
        </div>
    </main>

    <!-- Footer -->
    <footer class="bg-gray-900 text-gray-300 py-10">
        <div class="container mx-auto max-w-6xl px-4">
            <div class="flex flex-col md:flex-row justify-between items-center">
                <div class="mb-4 md:mb-0">
                    <h3 class="text-xl font-bold text-white">技术小馆</h3>
                </div>
                <div>
                    <a href="http://www.yuque.com/jtostring" class="text-gray-300 hover:text-white transition duration-300">
                        <i class="fas fa-external-link-alt mr-2"></i> http://www.yuque.com/jtostring
                    </a>
                </div>
            </div>
            <div class="border-t border-gray-800 mt-8 pt-8 text-center text-sm">
                <p>© 2023 技术小馆. 保留所有权利.</p>
            </div>
        </div>
    </footer>

    <script>
        mermaid.initialize({
            startOnLoad: true,
            theme: 'dark',
            sequence: {
                diagramMarginX: 50,
                diagramMarginY: 10,
                boxTextMargin: 5,
                noteMargin: 10,
                messageMargin: 35,
                mirrorActors: false
            }
        });
        
        // 平滑滚动
        document.querySelectorAll('a[href^="#"]').forEach(anchor => {
            anchor.addEventListener('click', function (e) {
                e.preventDefault();
                document.querySelector(this.getAttribute('href')).scrollIntoView({
                    behavior: 'smooth'
                });
            });
        });
    </script>
</body>
</html>
```